import { reactive } from 'vue'
import { getRolePageList, updateRoleStatus } from '@/api/system/role'

export function useDetail() {
  const status = reactive({
    saving: false,
    loading: false
  })

  const getRoleList = async (data: any) => {
    return getRolePageList(data)
  }

  const updateRoleStatusById = async (id: any, status: any) => {
    return updateRoleStatus(id, status)
  }
  return { status, getRoleList, updateRoleStatusById }
}
